package com.headingdata.overload;

public class MethodOverLoadTest1 {
    public static void main(String[] args) {
        // 了解重载
        // 发射火箭
        fire();
        fire("米国");
        fire(10,"印度");
    }
    public static void fire(){
        fire("岛国");
    }
    public static void fire(String country){
        fire(1,country);
    }
    public static void fire(int num, String country){
        System.out.println("发射" + num + "枚导弹给" + country);
    }
}
